package com.vctgo.evidence.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.vctgo.common.core.annotation.Excel;
import com.vctgo.common.core.web.domain.TenantEntity;
import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.util.List;

/**
 * 凭证列表对象 tb_evidence
 *
 * @author vctgo
 * @date 2024-12-15
 */
@Data
@TableName("tb_evidence")
@Document(indexName = "tb_evidence")
public class EsEvidence extends TenantEntity {

    private static final long serialVersionUID = 1L;

    /** 序号 */
    @TableId
    @Id
    private Long id;

    /** 凭证类型 */
    @Excel(name = "凭证类型")
    private Long evidenceType;

    /** 单据 */
    @Excel(name = "单据")
    private String receipts;

    /** 账套外键 */
    @Excel(name = "账套外键")
    private Long accountSetId;


    @TableField(exist = false)
    private Integer pageSize;

    @TableField(exist = false)
    private Integer pageNum;

    @TableField(exist = false)
    private List<TbEvi> tbEviList;

    /** 摘要 */
    @Excel(name = "摘要")
    @TableField(exist = false)
    @Field(type = FieldType.Text, analyzer = "ik_max_word")
    private String digest;

    /** 会计科目 */
    @Excel(name = "会计科目")
    @Field(type = FieldType.Text, analyzer = "ik_max_word")
    @TableField(exist = false)
    private String accountingSubject;


}
